package com.qiang.work.test09;

import java.util.Properties;
import java.util.Random;

public class Stu implements Runnable {
    private int number = 10;
    //    Random r = new Random();
//    int i = r.nextInt(10) + 1;
    // private Object obj = new Object();

    @Override
    public void run() {
        while (number > 0) {
            try {
                Thread.sleep(500);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            System.out.println(Thread.currentThread().getName() + "接收注射");
            number--;
        }
    }
}

